package jenum.com;

/**
 * Created by as on 2016/11/17.
 */
enum BookType{Business, Literature, Computer, Other};
public class BookNew {
    private BookType type;
    public void setType(BookType type)
    {
        this.type = type;
    }
    public BookType getType()
    {
        return type;
    }
}

class Enums_TypeSafe{
    public static void main(String args[])
    {
        BookNew bookNew = new BookNew();
        bookNew.setType(BookType.Business);
        System.out.print(bookNew.getType());
    }
}
